home *** CD-ROM | disk | FTP | other *** search
/ Fritz: All Fritz / All Fritz.zip / All Fritz / FILES / SPREOTUS / 123PERFI.LZH / TREND123.DOC < prev    next >
Text File  |  1984-02-23  |  3KB  |  64 lines

  1.                                    TREND123
  2.                                  version 1.0
  3.                        A Lotus 123 Curve fitting macro
  4.                created by John C. Dannenfeldt (Compuserve 71435,561)
  5.  
  6. The file TREND123.WKS is a independent macro that may be used within any Lotus 
  7. 123 spreadsheet.  This version enables you to create a set of data points with 
  8. the range name LINE or CURVE which fit any set of data points you range name 
  9. DATA with either a least squares straight line or an exponential curve:
  10.  
  11.      Linear (LINE)-         y=(c1 * x) + c2
  12.      
  13.      Exponential (CURVE)-   ln y=(c1 * x) + c2
  14.  
  15. Restrictions:
  16.      The DATA range must be continous.. no blank cells.
  17.      ...     ...    must be less than 257 points long.
  18.      You must be at A70 before you load the macro into your worksheet.
  19.      Your spreadsheet must not extend beyond A1..IV69 or it may be partially 
  20.         overwritten.
  21.  
  22. Instructions:
  23.      Before running the macro you must:
  24.           1) Define a continuous set of numbers range named DATA.
  25.                They may be in either a row or column orientation but the 
  26.                program takes much longer to work on the vertical ranges 
  27.                because it must first transpose them into a horizontal range.
  28.           
  29.           2) Name the macro so that you can call it by typing:
  30.  
  31.                /RNC\t  then press (ENTER)
  32.                A70     then press (ENTER)              
  33.  
  34.           3) Load the macro into your spreadsheet- 
  35.              Now goto A70 and type:
  36.    
  37.                /FCCETREND123   then press (ENTER)
  38.  
  39.     To activate the macro type ALT-T and follow the instructions.  When the 
  40.     macro is done it will return you to its main menu and ask if you would 
  41.     like to do a linear or exponential curve fit or quit.  If you do a 
  42.     different curve fit the old LINE or CURVE will be destroyed.  If you quit 
  43.     you may then look at LINE or CURVE directly or even better graph it beside 
  44.     the original DATA that you were trying to fit the curve to.
  45.     
  46. Comments:
  47.      I was forced to create some type of curve fitting regime for an 
  48. application I had and in the process developed part of the current macro.  The 
  49. next version will include some additional curve fitting routines such as 
  50. parabolic, moving averages and exponential smoothing.
  51.      Some of the things I don't like about this macro are a result of the 
  52. limitations of the 123 macro language.  After finally figuring out how to 
  53. transpose a column into a row I certainly wished that 123 had a general 
  54. command for that function.  Hopefully the next version will have an easier to 
  55. use macro language.
  56.      Feel free to make changes to the routine to fit your needs.  Some obvious 
  57. variants would be a basically vertical layout (which would make vertical 
  58. ranges faster to input) and locating the origin of the macro at a point more 
  59. suitable for your particular spreadsheet( remember that all references to 
  60. cells within a macro must be changed for it to work in a new location).  
  61.      If you got this macro in the form TREND123.HEX you must convert it to a 
  62. binary file called TREND123.WKS before trying to use it in a worksheet.
  63.  
  64.  If you have any suggestions contact me on COMPUSERVE at the IBMPC SIG.  END123.WKS befor